A system has been known in which a host device is combined with a slave device which communicates with the host device, executes processing corresponding to a situation and transmits a present state and a processed result to the host device. As an example of such system, a system is known in which a host computer (host device) is combined with a card reader (slave device). In such card readers, two different types of communication interfaces (input/output interface) such as RS232C and USB are used although the data-processing function is the same. In this case, their programs have been required to be managed independently.
As described above, in a card reader which communicates with a host device (for example, a host computer or a processing device such as a control device or an arithmetic device incorporated into a computer which is connected to the card reader), when different communication interfaces such as RS232C and USB are used, different programs are required to be integrated for every communication interface although the processing contents of data are the same (for example, see Japanese Patent Laid-Open No. Hei 8-288979). In other words, even when functions for carrying out a command from a host device are the same and are used for general purposes, it is the case that respective functions such as a command data receiving function, a command analyzing function, and a response transmitting function are formed to be non-general as dedicated to USB or RS232C, different programs are incorporated for every communication interface (see FIG. 12). In other words, a plurality of programs are prepared in which their substantial contents are the same but their specifications on communication are different.
Further, a card reader is disclosed which is provided with three different communication interfaces for RS232C, USB and LAN in order to communicate with a host device (for example, see Japanese Patent Laid-Open No. 2003-187193). In this card reader, data with regard to electronic money is received from the host device through a communication interface for USB, data with regard to a credit card is received from another host device through a communication interface for RS232C, and in this manner, data is communicated with each other.
However, when the management of different programs to every communication interface is executed as described above, in the case that a modification is required except a function on a communication section, for example, a common function, the respective programs are required to be modified and thus a lot of time and effort is needed. In addition, verifications whether modified programs operate without a problem or not are required to be performed for respective card readers whose communication interfaces are different and thus a development period becomes longer.
Further, there are similar problems in a card reader which is provided with, for example, three different types of communication interfaces in order to communicate with host devices. In other words, when each of the communication interfaces is set to be one-for-one with a host device that performs processing (for example, Japanese Patent Laid-Open No. 2003-187193), a common function is required to be modified in correspondence with each program because a program such as for RS232C and for USB is independently managed on the basis of an instruction from the host device.
In addition, in the above-mentioned card reader, when a system integrated with a communication interface for USB is changed to a communication interface for RS232C to communicate regarding electronic money, a program integrated with a communication interface for RS232C is independently managed separately from a program integrated with a communication interface for USB for communication regarding electronic money. Therefore, the integrated programs have to be modified every time a malfunction is corrected or security is enhanced. Moreover, verification whether the modified program is normally operated or not has to be executed and thus a lot of time and effort are needed.